function intersect(one, two) {
	if(!Array.isArray(one) || !Array.isArray(two)) {
		return []
	}


	var ele, result = []
	for (var i = 0; i < one.length; i++) {
		ele = one[i]
		if(two.includes(ele)) {
			result.push(ele)
		}
	}

	return result
}



// 交集的数组 也可能含有重复的元素
console.log( intersect(['a', 'b', 'c', 'b','b'], ['b', 'c', 'e']))

console.log(intersect(['c', 1, 'b'], [ 'b', 'c', 'b', 'b' ]))
